<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <link href="https://cdn.staticfile.org/twitter-bootstrap/5.1.1/css/bootstrap.min.css" rel="stylesheet">
    <script src="https://cdn.staticfile.org/twitter-bootstrap/5.1.1/js/bootstrap.bundle.min.js"></script>
</head>
<body>
<div class="container mt-3">
    <h2>请登录</h2>
    <div class="row">
        <div class="col-md-4 col-md-offset-2">
            <p style="color: red;" th:text="${msg}"></p>
        </div>
    </div>
    <form th:action="@{/login}" method="post">
        <div class="mb-3 mt-3">
            <label for="name" class="form-label">用户名：</label>
            <input type="name" class="form-control" id="name" placeholder="Enter name" name="name">
        </div>
        <div class="mb-3">
            <label for="password" class="form-label">密码：</label>
            <input type="password" class="form-control" id="password" placeholder="Enter password" name="password">
        </div>
        <div class="form-check mb-3">
            <label class="form-check-label">
                <input class="form-check-input" type="checkbox" name="remember"> Remember me
            </label>
        </div>
        <button type="submit" class="btn btn-primary">登录</button>
    </form>
    <p th:text="${error}"></p>
</div>
</body>
</html>